/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package proyecto;

import java.util.*;

/**
 *
 * @author Alex
 */
public class Cola {
    List<int[]> cola;
    
    public Cola(){
        cola = new ArrayList();
    }
    
    public void mete(int p1, int p2){
        int[] bloque = new int[2];
        bloque[0] = p1;
        bloque[1] = p2;
        cola.add(bloque);
    }
    
    public int[] saca(){
        int[] bloque = cola.get(0);
        cola.remove(0);
        return bloque;
    }

    public int numElem(){
       return cola.size();
    }

    public boolean vacio(){
        return cola.isEmpty();
    }
}
